package com.yuanqi.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yuanqi.pojo.Product;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;

/**
* @author LENOVO
* @description 针对表【product(商品SPU)】的数据库操作Mapper
* @createDate 2025-08-26 15:23:02
* @Entity com.yuanqi.pojo.Product
*/
@Mapper
public interface ProductMapper extends BaseMapper<Product> {
    // 自定义分页联表查询（分类名、品牌名）
    IPage<Product> selectPageWithNames(
            Page<Product> page,
            @Param("productName") String productName,
            @Param("categoryId") Long categoryId,
            @Param("startTime") Date startTime,
            @Param("endTime") Date endTime
    );
}




